﻿using Microsoft.Kinect;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace KinectLibrary
{
    [Serializable]
    public sealed class Articulation
    {
        public Vector Position { get; set; }
        public JointType JointType { get; set; }

        public static Articulation ConvertFromJoint(Joint joint)
        {
            var position = new Vector();
            position.X = joint.Position.X;
            position.Y = joint.Position.Y;
            position.Z = Vector.Zero.Z; //Thousand.Z
            return new Articulation()
            {
                Position = position,
                JointType = joint.JointType
            };
        }

        public static int MaxJoints { get { return 12; } } // Max fingers per hand.
    }
}
